package com.xiangyang.entity;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.SuperBuilder;

@Data
@SuperBuilder
@AllArgsConstructor
@NoArgsConstructor
public class PatientDetails extends BaseEntity {
    private Long registrationId;//挂号id
    private Long patientsId;//患者id
    private Long doctorId;//医生id
    private Integer age;//年龄
    private String gender;//性别
    private String identityCard;//身份证号
    private String address;//地址
    private String MedicalHistory;//病史
    private String allergen;//过敏源
    private Long statusId;//状态id
    private String createdAt;//创建时间
    private String updatedAt;//更新时间
     // 重写 BaseEntity 的 getId 和 setId 方法
    @Override
    public Long getId() {
        return getRegistrationId();
    }

    @Override
    public void setId(Long registrationId) {
        setRegistrationId(registrationId);
    }



    public void setPostId(Long registrationId) {
        this.registrationId = registrationId;
        // 同步设置 BaseEntity 的 id
        super.setId(registrationId);
    }
}
